﻿using System;
using System.Collections.Generic;
using System.Text;

namespace ObserverPattern
{
    public class Class2
    {
        public void T2()
        {
            SubJect subject = new SubJect();
            ObServer observer = new ObServer();
            ObServer2 observer2 = new ObServer2();
            subject.NotifyEvent += new SubJect.NotifyHandler(observer.CloseWindow);
            subject.NotifyEvent += new SubJect.NotifyHandler(observer2.Fuser);
            subject.Status = "落雨啦！！！！";
            subject.On_Notify();
            Console.ReadLine();
        }
    }
}
